package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.TeaShopOrderMapper;
import com.ruoyi.system.domain.TeaShopOrder;
import com.ruoyi.system.service.ITeaShopOrderService;
import com.ruoyi.common.core.text.Convert;

/**
 * 订单信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-12-31
 */
@Service
public class TeaShopOrderServiceImpl implements ITeaShopOrderService 
{
    @Autowired
    private TeaShopOrderMapper teaShopOrderMapper;

    /**
     * 查询订单信息
     * 
     * @param id 订单信息主键
     * @return 订单信息
     */
    @Override
    public TeaShopOrder selectTeaShopOrderById(Long id)
    {
        return teaShopOrderMapper.selectTeaShopOrderById(id);
    }

    /**
     * 查询订单信息列表
     * 
     * @param teaShopOrder 订单信息
     * @return 订单信息
     */
    @Override
    public List<TeaShopOrder> selectTeaShopOrderList(TeaShopOrder teaShopOrder)
    {
        return teaShopOrderMapper.selectTeaShopOrderList(teaShopOrder);
    }

    /**
     * 新增订单信息
     * 
     * @param teaShopOrder 订单信息
     * @return 结果
     */
    @Override
    public int insertTeaShopOrder(TeaShopOrder teaShopOrder)
    {
        return teaShopOrderMapper.insertTeaShopOrder(teaShopOrder);
    }

    /**
     * 修改订单信息
     * 
     * @param teaShopOrder 订单信息
     * @return 结果
     */
    @Override
    public int updateTeaShopOrder(TeaShopOrder teaShopOrder)
    {
        return teaShopOrderMapper.updateTeaShopOrder(teaShopOrder);
    }

    /**
     * 批量删除订单信息
     * 
     * @param ids 需要删除的订单信息主键
     * @return 结果
     */
    @Override
    public int deleteTeaShopOrderByIds(String ids)
    {
        return teaShopOrderMapper.deleteTeaShopOrderByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除订单信息信息
     * 
     * @param id 订单信息主键
     * @return 结果
     */
    @Override
    public int deleteTeaShopOrderById(Long id)
    {
        return teaShopOrderMapper.deleteTeaShopOrderById(id);
    }
}
